from selenium import webdriver
from selenium.webdriver.common.by import By

#打开谷歌,打开so浏览器
driver = webdriver.Chrome()
driver.get("https://www.sogou.com/")

# XPATH模糊定位
form=driver.find_element(By.XPATH,"//*[contains(@type,'hidden')]")
print(form.get_attribute('outerHTML'))


driver.quit()